package com.ruoyi.mall.domain;

import java.math.BigDecimal;
import java.util.Date;
import com.fasterxml.jackson.annotation.JsonFormat;
import org.apache.commons.lang3.builder.ToStringBuilder;
import org.apache.commons.lang3.builder.ToStringStyle;
import com.ruoyi.common.core.annotation.Excel;
import com.fasterxml.jackson.annotation.JsonFormat;
import com.ruoyi.common.core.web.domain.BaseEntity;

/**
 * 支付流水对象 payment
 * 
 * @author luogongquan
 * @date 2024-10-17
 */
public class Payment extends BaseEntity
{
    private static final long serialVersionUID = 1L;

    /** 主键 */
    @JsonFormat(shape = JsonFormat.Shape.STRING)
    private Long id;

    /** 订单id */
    @Excel(name = "订单id")
    @JsonFormat(shape = JsonFormat.Shape.STRING)
    private Long orderId;

    /** 支付时间 */
    @JsonFormat(pattern = "yyyy-MM-dd")
    @Excel(name = "支付时间", width = 30, dateFormat = "yyyy-MM-dd")
    private Date paymentDate;

    /** 支付金额 */
    @Excel(name = "支付金额")
    private BigDecimal amount;

    /** 支付方式(1：微信，2：支付宝，3：银联) */
    @Excel(name = "支付方式(1：微信，2：支付宝，3：银联)")
    private String paymentMethod;

    /** 支付状态（1:未支付，2：已支付，3：退款中，4：已退款） */
    @Excel(name = "支付状态", readConverterExp = "1=未支付，2=支付失败，3=已支付，4=退款中，5=已退款")
    private String paymentStatus;

    /** 支付备注信息 */
    @Excel(name = "支付备注信息")
    private String notes;

    /** 退款单id */
    @Excel(name = "退款单id")
    @JsonFormat(shape = JsonFormat.Shape.STRING)
    private Long orderReturnId;

    public void setId(Long id) 
    {
        this.id = id;
    }

    public Long getId() 
    {
        return id;
    }
    public void setOrderId(Long orderId) 
    {
        this.orderId = orderId;
    }

    public Long getOrderId() 
    {
        return orderId;
    }
    public void setPaymentDate(Date paymentDate) 
    {
        this.paymentDate = paymentDate;
    }

    public Date getPaymentDate() 
    {
        return paymentDate;
    }
    public void setAmount(BigDecimal amount) 
    {
        this.amount = amount;
    }

    public BigDecimal getAmount() 
    {
        return amount;
    }
    public void setPaymentMethod(String paymentMethod) 
    {
        this.paymentMethod = paymentMethod;
    }

    public String getPaymentMethod() 
    {
        return paymentMethod;
    }
    public void setPaymentStatus(String paymentStatus) 
    {
        this.paymentStatus = paymentStatus;
    }

    public String getPaymentStatus() 
    {
        return paymentStatus;
    }
    public void setNotes(String notes) 
    {
        this.notes = notes;
    }

    public String getNotes() 
    {
        return notes;
    }
    public void setOrderReturnId(Long orderReturnId) 
    {
        this.orderReturnId = orderReturnId;
    }

    public Long getOrderReturnId() 
    {
        return orderReturnId;
    }

    @Override
    public String toString() {
        return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
            .append("id", getId())
            .append("orderId", getOrderId())
            .append("paymentDate", getPaymentDate())
            .append("amount", getAmount())
            .append("paymentMethod", getPaymentMethod())
            .append("paymentStatus", getPaymentStatus())
            .append("notes", getNotes())
            .append("createTime", getCreateTime())
            .append("updateTime", getUpdateTime())
            .append("orderReturnId", getOrderReturnId())
            .toString();
    }
}
